<LINK href="http://cms.f.itc.cn/upload/ihome/js/calendar/css/calendar.css" type="text/css" rel="stylesheet" />
<LINK href="http://cms.f.itc.cn/upload/ihome/js/calendar/css/alternate.css" type="text/css" rel="stylesheet" />
<style type="text/css">
.small { font-size: 0.8em; }
</style>
<script type="text/javascript" src='http://cms.f.itc.cn/upload/ihome/js/calendar/mootools.js'></script>
<script type="text/javascript" src='http://cms.f.itc.cn/upload/ihome/js/calendar/calendar.rc4.js'></script>
			<div class="box02_1">
				<div class="search02 clear">
				<form action="" method="get">
					时间段：<input type="text" class="in2" style="width:70px;" id="begin_time" size="10" name="start" value='<{$start}>' /> <input type="text" class="in2" style="width:70px;" id="end_time" size="10" name="end" value='<{$end}>' />
					<select name="top">
					 <option value="10" <{if $top==10}>selected="true"<{/if}>>top10</option>
					 <option value="20" <{if $top==20}>selected="true"<{/if}>>top20</option>
					 <option value="30" <{if $top==30}>selected="true"<{/if}>>top30</option>
					 <option value="50" <{if $top==50}>selected="true"<{/if}>>top50</option>
					 <option value="100" <{if $top==100}>selected="true"<{/if}>>top100</option>
					</select>
					<select name="order">
					 <option value="ip_desc" <{if $order=='ip_desc'}>selected="true"<{/if}>>按uv降序</option>
					 <option value="ip_asc" <{if $order=='ip_asc'}>selected="true"<{/if}>>按uv升序</option>
					 <option value="pv_desc" <{if $order=='pv_desc'}>selected="true"<{/if}>>按pv降序</option>
					 <option value="pv_asc" <{if $order=='pv_asc'}>selected="true"<{/if}>>按pv升序</option>
					</select>
					商铺名称：<input type="text" class="in2" style="width:100px;" name="merchant_name" value="<{$merchant_name}>" />
					商品名称：<input type="text" class="in2" style="width:100px;" name="goods_name" value="<{$goods_name}>" />
					<input type="submit" value="查询" />
				</form>
				</div>
				<span style="font-size:16px;">店铺访问流量排行：</span>
                <div class="box02_Tab">
                	<div class="table01">
                    	<table cellpadding="0" cellspacing="0" width="100%" border="0" id="table">
                        <tr class="th">
                        <th><div>店铺名称</div></th>
                        <th><div>pv</div></th>
						<th><div>uv</div></th>
						<th><div>pv/uv</div></th>
						<th><div>订单数</div></th>
						<th><div>流水</div></th>
						<th><div class="small">店铺收藏</div></th>
						<th><div class="small">商品收藏</div></th>
						<th><div>评论</div></th>
						<th><div title="商铺首页的留言数">留言</div></th>
						<th><div title="商品详情页的留言数">咨询</div></th>
						<th><div title="IM工具咨询的唯一用户数">客询uv</div></th>
						<th><div title="IM工具咨询的点击数">客询pv</div></th>
						<th><div title="总咨询数=留言+咨询+IM咨询UV数">总咨询</div></th>
						<th><div>详情</div></th>
						<th><div>日流量</div></th>
                        </tr>
						<{foreach from=$shop_datas item=item}>
						<tr>
   						<td width="10%"><a href="/orders/list?merchant_id=<{$item.uid}>" target="_blank"><{$item.name}></a></td>
						<td width="3%"><{$item.pv}></td>
						<td width="2%"><{$item.ip}></td>
						<td width="5%"><{$item.pv_uv}></td>
						<td width="5%"><{$item.orders}></td>
						<td width="10%" style="color:red;"><{$item.money}></td>
						<td width="5%"><{$item.shop_fav}></td>
						<td width="5%"><{$item.goods_fav}></td>
						<td width="5%"><{$item.comments}></td>
						<td width="5%"><{$item.messages}></td>
						<td width="5%"><{$item.consults}></td>
						<td width="5%"><{$item.im_ip}></td>
						<td width="5%"><{$item.im_pv}></td>
						<td width="5%"><{$item.consults_all}></td>
						<td width="5%"><a href="<{$item.detail_url}>" target="_blank">查看</a></td>
						<td width="5%"><a href="http://<{$sub_domain}>/statis/dailyshop/<{$item.id}>" target="_blank">查看</a></td>
						</tr>
						<{/foreach}>
                        </table>
                    </div>
                </div>

				<span style="font-size:16px;">商品访问流量排行：</span>
                <div class="box02_Tab">
                	<div class="table01">
                    	<table cellpadding="0" cellspacing="0" width="100%" border="0" id="table">
                        <tr class="th">
                        <th><div>商品名称</div></th>
                        <th><div>pv</div></th>
						<th><div>uv</div></th>
						<th><div>pv/uv</div></th>
						<th><div>详情</div></th>
                        </tr>
						<{foreach from=$goods_datas item=item}>
						<tr>
   						<td width="50%"><a href="<{$item.url}>" target="_blank"><{$item.name}></a></td>
						<td width="20%"><{$item.pv}></td>
						<td width="10%"><{$item.ip}></td>
						<td width="10%"><{$item.pv_uv}></td>
						<td width="10%"><a href="<{$item.detail_url}>" target="_blank">查看</a></td>
						</tr>
						<{/foreach}>
                        </table>
                    </div>
                </div>

<script>
window.addEvent('domready', function() {
	myCal = new Calendar({ begin_time: 'Y-m-d'},{classes:['alternate'],navigation:2,tweak:{x:0,y:-20}});
	myCal = new Calendar({ end_time: 'Y-m-d'},{classes:['alternate'],navigation:2,tweak:{x:0,y:-20}});

	$begin_str = '';
	var begin_time = $('begin_time');
	if (begin_time.value == '') begin_time.value = $begin_str;
		begin_time.onfocus = function() {
		this.className = 'in1';
		if(this.value == $begin_str) this.value='';        
	}
	begin_time.onblur = function() {
		this.className='in2';
		if(this.value=='') this.value = $begin_str;
	}

	$end_str = "";
	var end_time = $('end_time');
	if (end_time.value == '') end_time.value = $end_str;
	end_time.onfocus = function() {
	this.className = 'in1';
	if(this.value == $end_str) this.value='';        
	}
	end_time.onblur = function() {
	this.className='in2';
	if(this.value=='') this.value = $end_str;
	}
																								 
});

</script>

